﻿<div class="head">
    <div class="headtop">
    <div class="top">
        <span class="tip">聚焦心脑，珍医无限－－打造中国最实用的专业医学网站</span>
        <div class="login">
            <a href="javascript:void(0);" class="tico1" onclick="SetHome(window.location)" >设为首页</a>

            [#if user??]<a href="${ctx}/my.jspx">欢迎,&nbsp;&nbsp;${user.printName}</a><a href="${ctx}/logout.jspx">[退出]</a>
            [#else]
            <a class="tico2" href="${ctx}/login.jspx">登录</a>
            <a class="tico3" href="${ctx}/register.jspx">注册</a>
            [/#if]

            <a href="javascript:void(0);" onClick="addBookmark()" class="tico4">收藏珍医网</a>
        </div>
    </div>
    </div>
    <div class="tbanner">
        <a href="/"><h1>珍医网</h1></a>
        <div class="tbanpic"><img src="_files/img/ban.jpg" width="722" height="100" /></div>
    </div>
    <div class="headdown">
    <div class="nav"><div class="seach"><input name="txtKeywords" id="searchAll" type="text" class="input" /><a href="javascript:searchAll();" class="seabtn">搜索</a></div>
        &nbsp;&nbsp;<a href="/"  >首页</a>&nbsp;&nbsp;|&nbsp;&nbsp;
        <a href="/node/36.jspx"  >医学资讯</a>&nbsp;&nbsp;|&nbsp;&nbsp;
        <a href="/node/75.jspx"  >会议纵横</a>&nbsp;&nbsp;|&nbsp;&nbsp;
        <a href="/node/77.jspx"  >在线学习</a>&nbsp;&nbsp;|&nbsp;&nbsp;
        <a href="/node/76.jspx"  >论文天地</a>&nbsp;&nbsp;|&nbsp;&nbsp;
        <a href="/node/82.jspx"  >病例管理</a>&nbsp;&nbsp;|&nbsp;&nbsp;
        <a href="/node/83.jspx"  >医患关系</a>&nbsp;&nbsp;|&nbsp;&nbsp;
        <a href="/my.jspx"  >会员中心</a></div>
    </div>
</div>
<script type="text/javascript">
    function addBookmark() {
        var title = "", url = "http://www.zhendoc.com";// 页面网址;
        if (!title) {
            title = document.title;
        }
        if (!url) {
            url = window.location.href;
        }
        try {
            window.external.addFavorite(url, title);
        }
        catch (e) {
            try {
                window.sidebar.addPanel(title, url, "");
            }
            catch (e) {
                alert("抱歉，您所使用的浏览器无法完成此操作。\n\n加入收藏失败，请使用Ctrl+D进行添加");
            }
        }
    }

    function SetHome(url) {
        if (document.all) {
            document.body.style.behavior = 'url(#default#homepage)';
            document.body.setHomePage(url);
        } else {
            alert("您好,您的浏览器不支持自动设置页面为首页功能,请您手动在浏览器里设置该页面为首页!");
        }
    }

    function searchAll() {
        var keywords = $("input[name='txtKeywords']").val();
        if ($.trim(keywords) != "") {
            window.location.href = '${ctx}/search.jspx?q=' + encodeURI(keywords);
        }
    }
    $(function(){
        $(".headtop").pin();
        document.onkeydown=function(event){
            var e = event || window.event || arguments.callee.caller.arguments[0];
            if(e && e.keyCode==13){ // enter 键
                if(document.activeElement.id=="searchAll") {
                    searchAll();
                }
                if(document.activeElement.id=="searchLw"){
                    searchLw();
                }
            }
        };
    });
</script>